package com.design.design.pattern.creational.factory.simplefactory;

/**
 * @author TomDragon
 */
public class VideoFactory01 {
    public Video getVideo (String type) {
        String java = "java";
        String python = "python";

        if (java.equalsIgnoreCase(type)) {
            return new JavaVideo();
        }else if (python.equalsIgnoreCase(type)) {
            return new PythonVideo();
        }
        return null;
    }
}
